Video compression with increased fidelity near horizon

ABSTRACT

A device and method for compressing image data. Image data is received comprising one or more images recorded by a camera. Attitude data is received indicating the attitude of the camera when each of the one or more images was recorded. In each of the one or more images, a region of interest is defined, the region of interest being bounded by a boundary, the boundary of the region of interest being based on the attitude data for the respective image and defining a section of the image within the region of interest and a section of the image outside the region of interest. Each of the one or more images is compressed, wherein the compression ratio applied to the section of the image outside the region of interest is higher than that applied to the section of the image within the region of interest.

FIELD OF THE INVENTION

Embodiments of the invention relate generally to a device and method forcompression with increased fidelity within a movable region of interest.

BACKGROUND

When storing or transmitting image or video data it is commonplace tocompress the data to reduce the number of bits that are required to betransmitted or stored. Compression often results in a loss ofinformation which in some circumstances may degrade the data to anunacceptable level. Many images or video streams contain one or moreregions in the frame or image which are of greater importance than theremaining area. For instance, in the case of surveillance or securityfootage, a certain region being viewed (such as a shop entrance) may beof greater interest, whereas other areas within the frame (such as theceiling) may be of less importance. Applying the same compression ratioacross the whole image or frame of the video feed can either result inexcessive image degradation within a region of interest or aninsufficient bit-rate reduction due to unnecessary image fidelityoutside of the region of interest.

BRIEF DESCRIPTION OF THE DRAWINGS

Embodiments of the present invention will be understood and appreciatedmore fully from the following detailed description, made by way ofexample only and taken in conjunction with drawings in which:

FIG. 1 shows a device for compressing image and/or video data accordingto an embodiment of the invention;

FIG. 2 depicts pitch, roll and yaw about an object;

FIG. 3 shows three examples of images including a region of interest;

FIGS. 4A-4D show a vessel 410 with a camera 420 mounted upon it and thevarious coordinate systems involved in the transformation from thereference coordinate system to the image coordinate system.

FIG. 5 shows a method of compressing a frame of video data; and

FIG. 6 shows a further device for compressing image and/or video dataaccording to an embodiment of the invention.

DETAILED DESCRIPTION

To allow an image or a frame from a video feed to be compressed to ahigher degree whilst also maintaining fidelity within a region ofinterest, embodiments of the present invention apply different levels ofcompression across the image. A higher level of compression is appliedoutside of the region of interest whilst a lower level of compression isapplied within the region of interest. The compression system thereforeprovides greater image fidelity within the region of interest thanoutside the region of interest.

Applying a reduced compression ratio within a region of interest is ofparticular use in the field of unmanned surface vehicles where theprimary area of interest is the horizon. An unmanned surface vehicle isa ship, boat or other vehicle which operates on the surface of the waterwithout a local operator. Accordingly, one or more cameras are requiredto help the operator remotely control the vehicle. The video has to betransmitted to the operator and, in order to meet bandwidth constraints,the image has to be compressed. In addition, where there is a largefleet of unmanned vehicles, compression becomes increasingly importantdue to bandwidth constraints associated with transmitting and receivinga large amount of video data.

The most important area in a video feed from a camera on a ship is thehorizon as this is where land masses and other vessels mostly appear.Having said this, the horizon is likely to move around the screen as thevessel (and therefore the camera attached to the vessel) pitches androlls on the sea. In this case, either a very large region of interestis used in order to ensure that the part of the scene which is ofinterest (in this case, the horizon) remains within the region ofinterest and therefore a reduced compression ratio is achieved, or asmaller region of interest is used risking the object moving out of theregion of interest and into a region of lower fidelity. Accordingly, aregion of interest which is fixed within the frame of the video feed isnot appropriate in situations where a large amount of camera motion islikely.

Image processing techniques may be used to determine the location of thehorizon (or any other relevant object of interest) in order to dictatethe position of the region of interest; however, this may not beeffective in low light conditions or poor light conditions in which itmay be difficult to discern the horizon or where parts of the horizonare obscured by land or other objects of lesser concern.

Accordingly, there is a need for an improved method of compressing imageand video data in order to accommodate situations in which a largeamount of camera motion is expected.

Accordingly, embodiments of the present invention provide a means ofcomputing the position of the region of interest in the image based onthe attitude of the camera to accommodate for camera motion. In oneembodiment, this is achieved by defining the region of interest as aregion fixed on a sphere encircling the camera. The sphere is fixed inrelation to the compass points (north, east, south, west, etc.).Accordingly, the sphere is also fixed in relation to the localhorizontal plane. The region of interest therefore remains fixed arounda particular direction regardless of the attitude of the camera.Embodiments of the invention use the attitude of the camera to apply atransform to convert the region of interest defined on the sphere into aregion of interest defined in terms of pixel coordinates within thefield of view of the camera. In this manner the rotation of the camerais compensated such that the region of interest in the image follows theobject of interest in the world. This allows the region of interest inthe image to be transformed to compensate for camera motion.

In one embodiment, the region of interest is defined as atwo-dimensional shape on the surface of a sphere, or on any twodimensional manifold that is capable of being mapped to all or part ofthe sphere. This two-dimensional surface is embedded within athree-dimensional reference coordinate system. The reference coordinatesystem is substantially co-centric with the camera coordinate system,and has an orientation that is arbitrary but known with respect to thecamera coordinate system. The camera coordinate system is centred on thecamera and is carried by it. Without loss of generality, if a sphere isused as the two dimensional manifold, it may be a unit sphere. Thisallows the boundary to be defined in terms of unit vectors.

According to a first aspect of the invention there is provided a devicefor compressing image data. The device comprises a controller configuredto receive image data comprising one or more images recorded by acamera, receive attitude data indicating the attitude of the camera wheneach of the one or more images was recorded, in each of the one or moreimages, define a region of interest bounded by a boundary, the boundaryof the region of interest being based on the attitude data for therespective image and defining a section of the image within the regionof interest and a section of the image outside the region of interest,and compress each of the one or more images, wherein the compressionratio applied to the section of the image outside the region of interestis higher than that applied to the section of the image within theregion of interest.

By defining the boundary of the region of interest in the image based onattitude data for the image, embodiments of the invention allow theregion of interest to be altered to accommodate for camera movement.Embodiments therefore allow the fidelity of less important sections ofan image to be reduced in order to provide an increased compression ofthe image, whilst also ensuring that the region of interest continues toencompass the most important section of the image even when the attitudeof the camera has changed. This may apply to a single image taken by acamera with a predefined region of interest and accompanying attitudedata. Alternatively, this may be applied to video data, with each imagein the video feed having a region of interest adapted based on itsrespective attitude data.

Applying a higher compression ratio to the image outside of the regionof interest may involve compressing the whole image, with a highercompression ratio being applied outside the region of interest, or onlycompressing the section of the image outside the region of interest.Accordingly, in one embodiment the controller is configured to compress,for each image, only the section of the image outside the region ofinterest.

Attitude data may include data indicating one or more of the pitch, yawand/or roll of the camera. The attitude data may be measured by anattitude sensor attached to the camera, or attached to any object whoseorientation relative to the camera is known, such as a surface vesselupon which the camera is mounted. The attitude data may comprise dataspecifying the attitude of an attitude sensor as well as data specifyingthe attitude of the camera relative to the attitude sensor. The dataspecifying the attitude of the camera relative to the attitude sensormay be stored in memory and received by the controller to be used todetermine the attitude of the camera based on the data specifying theattitude of the sensor.

In one embodiment, defining the region of interest in each of the one ormore images comprises transforming the boundary of the region ofinterest defined in a reference coordinate system into the boundary ofthe region of interest within the respective image based on the attitudedata for the image. The region of interest in the reference coordinatesystem may be defined as the region lying within a set of planes definedin the reference coordinate system.

The reference coordinate system may be a local level coordinate system.In one embodiment, the reference coordinate system is concentric withthe optical centre of the camera and is fixed with respect to compasspoints and with respect to the local horizontal plane. In oneembodiment, the reference coordinate system has axes aligned with East,North and Up and has its origin at the optical centre of the camera. Thereference coordinate system is therefore independent of the attitude ofthe camera.

The attitude data can then be used to transform the boundary of theregion of interest defined in the reference coordinate system into aboundary in the coordinate system of the image. In a further embodiment,the boundary of the region of interest is defined in the referencecoordinate system on a two dimensional manifold which is carried by thereference coordinate system. This provides a stable reference boundaryupon which subsequent transformations may be based. The coordinatesystem of the image may be a two dimensional coordinate systemrepresenting fixed positions within the image. This may be row andcolumn indices representing pixel locations or any other suitablecoordinate system.

Whilst the reference coordinate system may be centred on the opticalcentre of the camera, it may also be centred on another object attachedto the camera, such as an attitude sensor or a boat upon which thecamera is mounted.

The predefined region of interest may be input, for instance, by a uservia an input interface, or may be determined by the controller based onimage processing methods such as object recognition or edge detection.The predefined region of interest may be defined either as a region inan image, (such as in the 2D coordinates of the image) or as a region inthe reference coordinate system (such as 3D polar coordinates orCartesian coordinates centred on the camera).

According to a further embodiment, in the reference coordinate system,the boundary of the region of interest is static. For this embodiment,when a vessel carrying a camera translates through the water, theposition and orientation of the region of interest in the image remainsfixed But when the vessel rotates, the system applies a correspondingtransformation to the region of interest in the image, so that anyobject within the region of interest at the start of the rotation, ismaintained within the region of interest as the rotation progresses, foras long as it remains within the field of view of the camera.

In one embodiment, the two dimensional manifold is a sphere whose centreis located at the origin of the reference coordinate system and, in thereference coordinate system, the boundary of the region of interest isdefined using a series of points located on the surface of the sphere.The series of points define a set of lines forming the boundary of theregion of interest. Defining the region of interest in this mannerprovides an efficient basis for any transformations to account forchanges in attitude. The boundary may be defined in terms of unitvectors. In a spherical coordinate system this means that only theangles of the vectors defining the boundary need be considered.

By defining a region of interest on a sphere in a reference coordinatesystem whose orientation with respect to the camera is known by virtueof the attitude sensor, the attitude of the camera may be accounted forwhilst the region of interest continues to encompass the intended area.This allows a smaller region of interest to be used, thereby increasingthe amount by which the image may be compressed whilst still ensuringthe important sections of the image are represented with an acceptablefidelity. The transformation may utilise transformation matrices, suchas direction cosine matrices, or quaternions.

According to an additional embodiment of the invention, the controlleris configured to receive a reference image, attitude data for thereference image and data indicating the boundary of a region of interestwithin the reference image. The boundary of the region of interest inthe reference coordinate system is defined by transforming the boundaryof the region of interest in the reference image into the boundary ofthe region of interest in the reference coordinate system based on theattitude data for the reference image. In one embodiment, thetransformation from the reference image is a transformation onto the twodimensional manifold in the reference coordinate system. This allows theregion of interest to be conveniently defined in the coordinate systemof the reference image, for instance, by the user drawing a boundaryaround an important section of the image. Subsequently the boundary ofthe region of interest in the reference coordinate system is mapped to aboundary in the image coordinate system according to the attitude data,thereby determining the section of the image within the region ofinterest and the section of the image outside the region of interest.

According to an embodiment, the region of interest in the referencecoordinate system is defined based on a minimum and/or maximum thresholdfor elevation angle. In a further embodiment, the region of interest isdefined to lie between a minimum and maximum threshold for elevationangle. This allows the region of interest to be set above and below thehorizon to ensure that the horizon remains within the region of interestirrespective of the attitude of the camera.

According to a further embodiment, the region of interest in thereference coordinate system is defined based on a minimum and/or maximumthreshold for azimuth angle. In a further embodiment, the region ofinterest is defined to lie between a minimum and maximum threshold forazimuth angle. This allows the region of interest to be set on eitherside of a direction of interest in the reference coordinate system toensure that a path or object of interest remains within the region ofinterest irrespective of the attitude of the camera. Maximum and/orminimum angles for both elevation and azimuth may be defined. Where bothmaximum and minimum angles for azimuth and elevation are defined, theregion of interest is set to a rectangle in the reference coordinatesystem.

Whilst the above embodiments discuss maximum and minimum angles withrespect to the horizontal and north respectively, the threshold anglesmay equally be set with reference to any other axes provided these arefixed relative to the compass points and to the horizontal plane

According to an embodiment, the image data comprises first and secondimages recorded by the camera, and the boundary of the region ofinterest in the second image is defined based on a transformationapplied to the boundary of the region of interest in the first image.The transformation is based on the attitude data for the first andsecond images. This allows any change in the attitude of the camera tobe accounted for so that the region of interest remains focussed on therelevant section of the second image.

The first and second images may form part of a video feed, with theposition of the region of interest being updated for each image in thevideo feed in accordance with the attitude data for that image.Alternatively, the first and second images may be independent stillimages, with the first image forming a reference image in which theregion of interest may be defined by the user. The first and secondimages may be received at the same time, for instance, when the wholevideo is transferred in one go, or separately, as in the case ofstreaming video. The first image may be compressed before the secondimage is received and/or compressed. Alternatively, the first and secondimages may be compressed in parallel.

According to one embodiment, the transformation compensates for a changein the attitude of the camera between the recording of the first imageand the recording of the second image. This compensation keeps theregion of interest fixed in a particular direction in referencecoordinate space. The transformation may incorporate a magnification orother transformation to take into account any changes to themagnification applied to the image. Accordingly, where the magnificationfactor has changed between capturing the first and second images, thechange in magnification may be incorporated into the transformation ofthe boundary of the region of interest.

According to a further embodiment, compressing each of the one or moreimages comprises partitioning the image into blocks, computing adiscrete cosine transform for each block, and subsequently, quantisingtransform coefficients of the discrete cosine transform for each block.Applying a higher compression ratio to the section of the image outsidethe region of interest comprises applying a larger quantisation stepsize outside the region of interest than within the region of interest.Accordingly, the image may undergo transformation and quantisationcompression with a smaller quantisation step size being applied to thetransformed image data relating to the section of the image withinregion of interest. Alternatively, no quantisation may be applied withinthe region of interest.

In one embodiment, compressing the one or more images comprises, foreach of the one or more images, applying transform compression to theimage and wherein applying a higher compression ratio to the section ofthe image outside the region of interest comprises applying a differenttransformation to the section of the image outside the region ofinterest to the section of the image within the region of interest.

According to a second aspect of the invention there is provided a methodof compressing image data. The method comprises receiving image datacomprising one or more images recorded by a camera, receiving attitudedata indicating the attitude of the camera when each of the one or moreimages was recorded, and, in each of the one or more images, defining aregion of interest bounded by a boundary. The boundary of the region ofinterest is based on the attitude data for the respective image anddefines a section of the image within the region of interest and asection of the image outside the region of interest. The method furthercomprises compressing each of the one or more images, wherein thecompression ratio applied to the section of the image outside the regionof interest is higher than that applied to the section of the imagewithin the region of interest.

According to an embodiment, compressing each of the one or more imagescomprises, for each image, compressing only the section of the imageoutside the region of interest.

According to one embodiment, defining the region of interest in each ofthe one or more images comprises transforming the boundary of the regionof interest defined in a reference coordinate system into a boundary ofthe region of interest within the respective image based on the attitudedata for the image.

According to an embodiment, the reference coordinate system isconcentric with the optical centre of the camera and is fixed withrespect to compass points and with respect to the local horizontalplane.

According to one embodiment, the boundary of the region of interest isdefined in the reference coordinate system on a two dimensional manifoldwhich is carried by the reference coordinate system.

According to a further embodiment, on the manifold in the referencecoordinate system, the boundary of the region of interest is static.

According to an embodiment, the two dimensional manifold is a spherewhose centre is located at the origin of the reference coordinate systemand, in the reference coordinate system, the boundary of the region ofinterest is defined using a series of points located on the surface ofthe sphere.

According to one embodiment, the method further comprises receiving areference image, attitude data for the reference image and dataindicating the boundary of a region of interest within the referenceimage; and the boundary of the region of interest in the referencecoordinate system is defined by transforming the boundary of the regionof interest in the reference image into the boundary of the region ofinterest in the reference coordinate system based on the attitude datafor the reference image.

According to one embodiment, the region of interest in the referencecoordinate system is defined based on a minimum and/or maximum thresholdfor elevation angle.

According to a further embodiment, the region of interest in thereference coordinate system is defined based on a minimum and/or maximumthreshold for azimuth angle

According to a further embodiment, the image data comprises first andsecond images recorded by the camera; and the boundary of the region ofinterest in the second image is defined based on a transformationapplied to the boundary of the region of interest in the first image,the transformation being based on the attitude data for the first andsecond images.

According to an embodiment, the transformation compensates for a changein the attitude of the camera between the recording of the first imageand the recording of the second image.

According to an embodiment, compressing each of the one or more imagescomprises partitioning the image into blocks, computing a discretecosine transform for each block, and subsequently, quantising thetransform coefficients of the discrete cosine transform for each block.Applying a higher compression ratio to the section of the image outsidethe region of interest comprises applying a larger quantisation stepsize outside the region of interest than within the region of interest.

According to an additional embodiment, compressing each of the one ormore images comprises, for each of the one or more images, applyingtransform compression to the image and applying a higher compressionratio to the section of the image outside the region of interestcomprises applying a different transformation to the section of theimage outside the region of interest to the section of the image withinthe region of interest.

Accordingly, embodiments of the invention allow a region of interest tobe set within an image based on the attitude of the camera when theimage was taken to compensate for camera motion. This allows a smallerregion of interest to be defined than otherwise would have been possiblein situations where a large amount of camera motion is expected.Accordingly, the image or images may be compressed by a larger amountwithout risking any loss of fidelity for the important sections of therecorded scene.

By defining a static region of interest on a sphere in a referencecoordinate system which is fixed with respect to the horizontal planeand to the compass points, the region of interest can remainencompassing a particular direction whilst transformations from thereference coordinate space to the image coordinate space based onattitude data allow the boundaries of the region of interest in imagestaken at various attitudes to be determined.

FIG. 1 shows a device for compressing image and/or video data accordingto an embodiment of the invention. The device comprises a controller 100comprising a compression module 110 and a region of interest (ROI)computation module 120. The compression module 110 is configured toreceive image and/or video data from a camera 130. The ROI computationmodule 120 is configured to receive attitude data from an attitudesensor 140. The camera attitude data provides information regarding theattitude of the camera 130. In one embodiment, the camera attitude datacomprises data relating to the pitch, roll and yaw of the camera 130.

The ROI computation module 120 is configured to calculate a region ofinterest within the field of view of the image or video based on thecamera attitude data. The region of interest is defined as a regionwithin a boundary defined in the image. The boundary may be a polygon.This region defines the pixels or blocks of pixels which are to becompressed at a lower compression ratio.

The information identifying the ROI pixels is transferred to thecompression module 110. If the attitude of the camera changes, theattitude sensor 140 detects this change and the ROI computation module120 transforms the boundary of the region of interest to compensate forthis change based on the camera attitude data. This means that therelevant area of the scene being viewed by the camera is kept within theregion of interest (provided that it is still within the field of viewof the camera).

The compression module 110 is configured to compress the image and/orvideo signal wherein a greater degree of compression is applied outsidethe region of interest than inside the region of interest. Thecompressed signal is then output. The compressed signal may be output toa transmitter to transmit to a remote operator, may be locally stored inmemory or may be output via an alternative output device such as adisplay.

The controller 100 is integrated into a compression device, the camera130 and attitude sensor 140 being external to the compression device,and the image/video signal and camera attitude data are received via aninput interface in the compression device. In an alternative embodimentthe controller is incorporated into the camera.

The attitude sensor 140 is attached to the camera 130. The attachmentmay be indirect by attaching the attitude sensor 140 to an objectattached to the camera 130. In one embodiment, the camera 130 is locatedon a vehicle and the attitude data is provided by an attitude sensorincorporated within the vehicle. In an alternative embodiment, theattachment is direct, that is, having direct contact between the camera130 and attitude sensor 140, e.g. by screwing the attitude sensor to thecamera. In a further embodiment, the attitude sensor 140 is integratedwithin the camera 130.

Whilst the compression module 110 and the region of interest computationmodule 120 are shown to be integrated into one controller 100 in FIG. 1,in an alternative embodiment the compression module 110 and ROIcomputation module 120 are within separate controllers.

Transforming a region of interest based on attitude data is an effectiveand efficient method which ensures that the important sections of aregion being imaged are maintained in high fidelity even in scenarioswhere there may be a large amount of camera movement, whilst stillallowing less important sections of an image or video to be compressedto a greater degree thereby increasing compression ratio.

The attitude sensor 140 may measure the attitude of the camera itself orof an object to which the camera is attached, such as a vessel. The ROIcomputation module 120 is then configured to transform the ROI based onthe attitude data relating to the attitude of the camera or otherobject.

Attitude can be described in terms of pitch, roll and yaw. FIG. 2depicts pitch, roll and yaw pertaining to an object 200. With referenceto the object 200, for instance a ship or a camera, pitch is the anglewhich the longitudinal axis 210 of the object 200 makes with thehorizontal plane. It therefore represents a rotation about the lateralaxis 220 of the object 200. Roll represents a rotation about thelongitudinal axis 210 of the object 200. Yaw represents a rotation aboutthe vertical axis 230 of the object 200.

FIG. 3 shows three examples of images including a region of interest330. FIGS. 3A, 3B and 3C represent the view from a camera mounted on thefront of a ship. The bow of the ship 310 can be seen at the bottom ofeach image. As this region shows the ship itself it is not of particularinterest to the user in the present example. As objects are most likelyto appear on the horizon 320 this is the most important section of theimage. Accordingly, the region of interest 330 is set to contain thehorizon 320 within a rectangular area spanning the entire width of theimage. This may be achieved by the initial or default position of theregion of interest 330 being predefined, for instance via an input fromthe user. Alternatively, an initialisation process may be implementedutilising edge detection or shape recognition to focus the region ofinterest 330 on the desired area of the image (in this case the horizon320).

FIG. 3B represents the view from a camera mounted on the front of a shipwherein the region of interest 330 is not transformed within the fieldof view of the camera to compensate for a change in attitude. In thisexample, the ship has pitched and rolled resulting in the horizon 320moving out of the static region of interest 330. Accordingly, thehorizon 320 is compressed at a higher level resulting in an unacceptableloss of fidelity at the horizon 320 whilst the region of interest 330contains a high fidelity image of the sky which in this case is notuseful to the user.

FIG. 3C shows the same view as FIG. 3B; however, in this case the regionof interest 330 has been moved within the image according to anembodiment of the present invention to compensate for the change inattitude. The region of interest 330 is translated from its originalposition as shown in FIG. 3A to a second position, lower in the image,to compensate for the pitch of the ship. In addition, the region ofinterest 330 has undergone a rotation to accommodate for the roll of theship. Without this rotation, the region of interest 330 would be centredon the horizon 320; however, it would not contain the full extent of thehorizon 320 which, due to the roll of the ship, would pass out of theregion of interest 330. The translation and rotation allow the region ofinterest 330 to track the horizon 320 as the ship pitches and rolls onthe sea. This maintains a high fidelity image of the horizon 320,compensating for camera movement whilst allowing less important aspectsof the image to be compressed to a higher degree to reduce the resultingimage data volume.

The region of interest may be any shape or size. Its boundaries andinitial position may be predefined based on settings stored in memory ormay be defined by a user. In addition, the compression ratio, bothinside and outside the region of interest, may be set by the user.

The region of interest may be moved based on any one of pitch, roll oryaw, or any combination of these parameters. In addition, as discussedbelow, non-linear transformations may be required, to account for theoptics of the camera.

In one embodiment, the region of interest is defined within a boundaryinscribed on the surface of a sphere, in a reference coordinate systemco-centric with the camera 130. In the present embodiment the referencecoordinate system has axes X, Y and Z parallel with East, North and Uprespectively; however, any orientation may be utilised provided thesphere has a fixed orientation in relation to the compass points so thata specified point of the sphere always points north, along thehorizontal (in practice, parallel to the surface of the earth at thespecified location). Based on this defined boundary and the attitudedata, the boundary of the region of interest within the image isdetermined via transformations of the boundary from the sphere to theimage coordinate system.

Various embodiments arise as refinements in which different methods areused to specify the boundary of the region of interest on the sphere. Inone embodiment the region of interest is defined based on elevationangle. In one embodiment, the region of interest is defined to liebetween a lower and an upper elevation angle. This allows a region ofinterest to be defined around the horizon, as in FIG. 3C.

In another embodiment, the boundary is defined in terms of upper andlower limits for the azimuth angle with the region of interest lyingtherebetween. This may be useful for monitoring a particular directionof interest.

In another embodiment the operator defines maximum and minimum elevationangles but also defines minimum and maximum azimuth angles. This may beuseful for defining a region of interest that emphasises a particularpart of the horizon, such as that containing a stationary object in thefar distance.

In further embodiments the region of interest is defined as a polygon onthe sphere, with the shape being specified by the coordinates of itsvertices.

In further embodiments the region of interest is defined as the regionenclosed by a set of planes in the reference coordinate system.

The ROI computation module 120 is configured to find a set of pixels orblocks of pixels in the image that fall wholly or partly within theboundary, taking into account the attitude information from the attitudesensor 140.

Embodiments employ a method by which points on the sphere arerepresented within the reference coordinate system. In severalembodiments, each point on the sphere is represented as a unit vector(v_(r)) in the reference coordinate system having coordinates {X, Y, Z}.These axes are fixed relative to the compass points. For example, theaxes might align with [East, North, Up]. Similarly, embodiments requirea representation by which each pixel in the image can be identified. Inseveral embodiments {row, column} indices are used to identify thelocation of respective pixels in the image coordinate system.

In some embodiments, the ROI computation module 120 operates byconstructing a list of vertices on the sphere that form the boundary ofthe region of interest, and for each such vertex, computing thecorresponding {row, column} image coordinates. These points define aregion in the image, and the ROI computation module 120 returns allpixels or blocks of pixels that lie within the region. This is achievedby transforming vectors for the vertices from the reference coordinatesystem into the image coordinate system.

To achieve the above, the ROI computation module is required totransform {X,Y,Z} coordinates on the sphere, into {row, column} imagecoordinates. This transformation consists of a rotation that takes thevector from the reference coordinate system to the camera coordinatesystem, followed by a transformation that computes the row and columnindices, this transformation being based on the characteristics of thecamera.

FIGS. 4A-4D show a vessel 410 with a camera 420 mounted upon it and thevarious coordinate systems involved in the transformation from thereference coordinate system to the image coordinate system.

FIG. 4A shows the reference coordinate system having axes X, Y and Z andwhich is centred on the optical centre of the camera 410.

The first transformation required is a transformation to account for theattitude of the vessel 410. This is a transformation from the referencecoordinate system to an attitude coordinate system. The attitudecoordinate system shown in FIG. 4B is aligned with the attitude of theboat 420. Accordingly, the attitude coordinate system is a vesselcoordinate system. In this embodiment, the vessel coordinate systemcomprises Forward, Left and VesselUp (F, L, VU) coordinates.

The attitude coordinate system is the coordinate system of the attitudesensor. Accordingly, in the present embodiment it is necessary totransform this coordinate system into a coordinate system which isaligned with the camera. The camera coordinate system is shown in FIG.4C. The camera coordinate system comprises right, down and forward (R, Dand F) coordinates.

Finally, a transformation is required to convert the camera coordinatesystem into a two dimensional image coordinate system. Thistransformation accounts for the optical properties of the camera toprovide a coordinate system which can represents pixel coordinates in animage. The image coordinate system is shown in FIG. 4D and comprises row(R) and column (C) indices. As a convention, the row coordinates aresmallest at the top of the image and therefore run from the top to thebottom of the image.

In one embodiment, the attitude sensor is attached to the vessel so thatits pitch, roll and yaw outputs are the pitch, roll and yaw of thevessel itself. The ROI computation module 120 receives the pitch, rolland yaw angles from the attitude sensor 140 and these are used tocompute a direction cosine matrix denoted M_(r) ^(v) that transformsvectors from the reference coordinate system into the vessel coordinatesystem. The camera has a fixed orientation with respect to the vessel,and this orientation is represented by a second direction cosine matrix(DCM), denoted M_(v) ^(c), that transforms vectors from the vesselcoordinate system into vectors in the camera coordinate system. Vectorsin the reference coordinate system are constrained to be unit vectors,and since the direction cosine matrices preserve this property, theresulting vectors in the camera coordinate system are unit vectors also.

In mathematical notation these steps are written as follows, for anembodiment in which the reference coordinate system has axes {X, Y, Z}.Let the yaw, also known as the heading, be denoted α, so that the vesselpoints due North when a=0. Let the pitch angle β be defined such thatpositive pitch raises the bow. Let the roll angle γ be defined such thatpositive roll rotates the mast to the starboard. Let the unit vector inthe reference coordinate system be v_(r) and let the vector in cameracoordinate system be v_(c). Then the direction cosine matrix M_(r) ^(v)is given by

$M_{r}^{v} = {\quad\begin{bmatrix}{{- {{Cos}\lbrack\beta\rbrack}}{{Sin}\lbrack\alpha\rbrack}} & {{{{Cos}\lbrack\alpha\rbrack}{{Cos}\lbrack\gamma\rbrack}} - {{{Sin}\lbrack\alpha\rbrack}{{Sin}\lbrack\beta\rbrack}{{Sin}\lbrack\gamma\rbrack}}} & {{{{Cos}\lbrack\gamma\rbrack}{{Sin}\lbrack\alpha\rbrack}{{Sin}\lbrack\beta\rbrack}} + {{{Cos}\lbrack\alpha\rbrack}{{Sin}\lbrack\gamma\rbrack}}} \\{{- {{Cos}\lbrack\alpha\rbrack}}{{Cos}\lbrack\beta\rbrack}} & {{{- {{Cos}\lbrack\gamma\rbrack}}{{Sin}\lbrack\alpha\rbrack}} - {{{Cos}\lbrack\alpha\rbrack}{{Sin}\lbrack\beta\rbrack}{{Sin}\lbrack\gamma\rbrack}}} & {{{{Cos}\lbrack\alpha\rbrack}{{Cos}\lbrack\gamma\rbrack}{{Sin}\lbrack\beta\rbrack}} - {{{Sin}\lbrack\alpha\rbrack}{{Sin}\lbrack\gamma\rbrack}}} \\{{Sin}\lbrack\beta\rbrack} & {{- {{Cos}\lbrack\beta\rbrack}}{{Sin}\lbrack\gamma\rbrack}} & {{{Cos}\lbrack\beta\rbrack}{{Cos}\lbrack\gamma\rbrack}}\end{bmatrix}}$

The rotation from the reference coordinate system to the cameracoordinate system is

v _(c) =M _(v) ^(c) M _(r) ^(v) v _(r)

Finally, this latter vector v_(c) is transformed into a vector in imagecoordinates, this being denoted v_(i) and comprising row and columnindices indicating the corresponding pixel within the image. Thistransformation being based on the characteristics of the camera: itsfocal length (f), horizontal and vertical angular extent, and the numberof pixels horizontally and vertically. Namely:

${row} = {{\frac{fD}{dF} + {r_{0}\mspace{31mu} {column}}} = {\frac{fR}{dF} + c_{0}}}$

where d is the pixel density, r₀ and c₀ are the row and columncoordinates for the optical centre of the image and R, D and F are theright, down and forward coordinates from the camera coordinate systemrespectively.

The general definition of a direction cosine matrix (DCM) between twosets of three dimensional coordinates is:

${DCM} = \begin{pmatrix}{\cos \mspace{11mu} \theta_{x_{1},x_{2}}} & {\cos \mspace{11mu} \theta_{x_{1},y_{2}}} & {\cos \mspace{11mu} \theta_{x_{1},z_{2}}} \\{\cos \mspace{11mu} \theta_{y_{1},x_{2}}} & {\cos \mspace{11mu} \theta_{y_{1},y_{2}}} & {\cos \mspace{11mu} \theta_{y_{1},z_{2}}} \\{\cos \mspace{11mu} \theta_{z_{1},x_{2}}} & {\cos \mspace{11mu} \theta_{z_{1},y_{2}}} & {\cos \mspace{11mu} \theta_{z_{1},z_{2}}}\end{pmatrix}$

where x₁, y₁, z₁ are the coordinate vectors for the first coordinateset, x₂, y₂, z₂ are the coordinate vectors for the second coordinate setand θ_(ab) is the angle between vectors a and b.

Various embodiments arise as refinements in which different methods areused to make the transformation from the reference coordinate system tothe camera coordinate system. The reference, attitude/vessel and cameracoordinate systems are shown as Cartesian coordinate systems but maywell be implemented as polar coordinate systems. The arrangement of thecoordinate systems in FIGS. 4A-D is shown as an example. Accordingly,any reference coordinate system may be used provided that it is fixedwith respect to the poles of the compass and the vertical and its originis static with respect to the camera 420. The attitude sensor need notbe attached directly to the vessel but to any object whose orientationwith respect to the camera is known, and in this case the vesselcoordinate system may be replaced with a separate sensor coordinatesystem. Any camera coordinate system may be used provided that it isaligned with and concentric with, the camera. Any image coordinatesystem may be used provided that it represents the location of pointswithin an image produced by the camera. Whilst the above embodimentsdescribe the relationship of the camera attitude to the attitude sensorattitude via a vessel coordinate system, this transformation is notnecessary and may be avoided in favour of a direct transformation fromthe attitude coordinate system to the camera coordinate system.Accordingly, instead of transforming from the reference coordinatesystem to the camera coordinate system via a vessel coordinate system,in one embodiment a direct transformation from the reference coordinatesystem to the camera coordinate system is implemented.

The transformation matrix M_(v) ^(c) may be predefined and stored inmemory, may be user defined, or may be determined by the system itself.The direction cosine matrix M_(r) ^(v) is calculated by the system basedon the attitude data.

Based on the above methods, the region of interest may be defined as astatic region on a sphere in the reference coordinate system so that itremains fixed encompassing a particular direction of interest. Theattitude data is then used to determine the required transformationmatrices (as discussed above) to determine which pixels in the imagefall within the region of interest. By applying the requiredtransformation matrices to the vectors for the boundary of the region ofinterest in the reference coordinate system, the region of interest maybe defined in the image coordinate system. As the transformation variesbased on the attitude data, the position of the region of interestwithin the image is varied to account for any change in attitude.

In another embodiment, the region of interest is defined between maximumand minimum boundaries for the elevation angle. Maximum and minimumazimuth angles may also be set. Information from the attitude sensor 140is then used to determine a DCM that defines the orientation of theattitude sensor 140, and thence into a DCM that defines the attitude ofthe camera 130 in the reference coordinate system. From this, geometrictransformations yield a definition of the lines representing the upperand lower boundaries of the region, expressed in pixel coordinates. Thisallows the region of interest to be defined based on boundaries aboveand below the horizon so that horizon remains within the region ofinterest, or based on a box encompassing an object of interest.

In further embodiments only partial attitude information is available,such as yaw only or yaw and pitch only. In these cases thetransformations may be simplified while retaining the intent of mappinga region of interest on the surface of a sphere in the referencecoordinate system to the image.

In a further embodiment the region of interest is defined within aboundary defined in the image coordinate system and the system infers acorresponding boundary on the sphere in the reference coordinate system.In a specific embodiment, the operator draws a boundary around an objectin an image. This provides the boundary for the region of interest inthe image coordinate system. The inverse of the transformations totransform from the reference coordinate system to the image coordinatesystem are used to determine the boundary coordinates of the region ofinterest on the sphere. The boundary coordinates on the sphere in thereference coordinate system are used, so that a transformation into theimage coordinate system for a subsequent image may account for anychange in the attitude of the camera.

Other means of using attitude data to determine a position or region inan image are available. For instance, as an alternative to directioncosine matrices, a quaternion representation can be used to transformreference coordinates to coordinates in the image with equivalenteffect.

FIG. 3 relates to single images. Embodiments of the present inventioncan be applied to a single image taken when the attitude of the camera,or another object connected to the camera, is known. Embodiments of thepresent invention may also be applied to compressing video data. Videodata can be considered as a stream of consecutive images, called frames.The amount of compression may be changed via various methods, eachdepending on the type of compression which is employed. Whilstembodiments of the present invention may utilise various means ofcompression, in one embodiment the data to be compressed is video dataand the method of compression complies with the H.264 standard.

FIG. 5 shows a method of compressing a frame of video data based onH.264. Compression is obtained in part through prediction. The frame isfirst divided 610 up into blocks of pixels called macroblocks. Thecontent of a macroblock may be predicted 620 based on information withinthe same frame (intraframe prediction) and/or information in one or moreother frames in the video sequence (interframe prediction), for instancethe preceding frame and/or the frame immediately following the currentframe.

Intraframe prediction relies on spatial redundancy. The pixels within amacroblock are predicted based on the pixels adjacent to the macroblock.Usually, the pixels running along the left hand side and the top of themacroblock are used. As the prediction is not perfect, the predictedblock is subtracted 630 from the original macroblock (or vice versa) toproduce a residual macroblock. A residual macroblock shows the errorproduced by the prediction. Each original macroblock can then bereconstructed (decompressed) using the data used for the prediction andthe residual macroblock. The compression results from the reduction inthe number of bits that are required to transmit the pixels used forprediction and the residual macroblock.

Interframe prediction makes use of temporal redundancy. As mentionedabove, interframe prediction compresses a given frame using one or morepreceding and/or succeeding frames in the video as reference frames.Usually, only neighbouring frames are used as reference frames (i.e. theframe immediately preceding and/or the frame immediately following theframe being compressed).

One example of interframe compression is block based motioncompensation. As in intraframe prediction, the frame being compressed isdivided up into macroblocks. For each macroblock, the preceding frame issearched using a block matching algorithm to find a block in thepreceding frame which is similar to said macroblock. If such a matchingblock is found, a motion vector is computed giving the direction andmagnitude of the offset between the position of the matching block inthe reference frame and the position of the macroblock being compressedin the present frame. The predicted macroblock is subtracted from theframe being compressed (or vice versa) in order to produce a residualmacroblock showing the errors in the prediction. A video decoder is ableto reconstruct the original macroblock once it has received and decodedthe predicted macroblock, as well as the motion vectors and the residualmacroblock. In addition to using the preceding frame as a referenceframe, the frame immediately following the frame being compressed mayalso be used as a reference frame. The reference frames themselves maybe compressed via intraframe predication.

Motion compensation utilising large macroblocks reduces the number ofdata vectors required but can increase the number of bits needed toencode the residual macroblocks, as using larger blocks can result ingreater error in the predicted frames. In comparison, using smallermacroblocks means that there is a greater chance that a closely matchingblock can be found in the reference frame, thereby reducing the numberof bits required to encode the residual macroblock, but increases thenumber of motion vectors required.

The size of macroblocks may either be predefined, or may be determinedbased on the content of the picture. For instance, some compressionmethods allow variable macroblock size, where the size of the macroblockis chosen dependent on the local complexity. One method begins with alarge macroblock for a region and splits the macroblock into a number ofsmaller macroblocks. This gives rise to improved compression for a givenerror requirement. The macroblocks are repeatedly split until either ablock is located within the reference frame which matches the block towithin an allowable error or a minimum block size is reached.

The above prediction methods are lossless, provided the residual blocksare encoded without error; however, greater compression can be achievedat the expense of information via transformation and quantisation, aswill be explained later.

A transformation 640, such as a discrete cosine transformation, isapplied to each residual macroblock. The discrete cosine transformdescribes the information within the macroblock in terms of cosines ofvarious frequencies. This allows effective compression as, for mostimages, the majority of the signal energy lies at low frequencies. Thehigh frequencies usually have small enough amplitudes that they may beneglected with little visible distortion. Accordingly, by separating thesignal into its respective frequencies, precision at higher frequenciescan be reduced via quantisation, resulting in a compressed signal withlittle signal degradation.

As an alternative to the direct cosine transform, H.264 applies amodified transform, based on the discrete cosine transform, with atransform matrix H of:

$H = \begin{bmatrix}1 & 1 & 1 & 1 \\2 & 1 & {- 1} & {- 2} \\1 & {- 1} & {- 1} & 1 \\1 & {- 2} & 2 & {- 1}\end{bmatrix}$

applied to 4×4 blocks within the residual macroblock. This achieves thesame function as the direct cosine transform; however, it has integercoefficients and is therefore less susceptible to rounding errors thanthe direct cosine transform, which has irrational coefficients.

The coefficients of the transformed macroblocks are quantised 650.Quantisation involves representing a range of values as a single integervalue. By applying this across the set of transform coefficients, theresulting signal can be described by a reduced number of discretesymbols thereby resulting in a more compressed signal.

Quantisation of the transformed macroblocks reduces the number of valuesrequired to represent the original signal, thereby achievingcompression. In addition, the coefficients for higher frequencies areoften quantised to zero, and this enables improved entropy coding (seebelow). In general, entropy coding benefits whenever the distribution isconcentrated in a smaller number of values and this is achieved via aquantisation step that leads to many values being zero.

In one embodiment, quantisation 650 involves dividing the transformcoefficient matrix by a predefined quantisation matrix. The quantisationmatrix is designed to provide greater resolution to more perceivablefrequency components over less perceivable components. Generally, thismeans that the quantisation matrix has higher values corresponding tohigher frequency components than those corresponding to lower frequencycomponents. The transform coefficient matrix (comprising thecoefficients of the transformed block) is divided by the quantisationmatrix and the resulting values are rounded to their nearest integers.The compression ratio can be varied by changing the quantisation matrix.Increasing the values in the quantisation matrix increases thequantisation step size and therefore increases compression.

Following quantisation, the quantised coefficients undergo entropycoding 660 to describe the data in a more efficient way. Entropy codingmethods are generally lossless data compression schemes where shortercodewords are assigned to the most common input values than to the rareinput values. Various methods of entropy coding are available, such asHuffman coding, Golomb coding or context-adaptive variable-lengthcoding.

The resulting compressed signal can then be stored in memory ortransmitted to a decoder so that it may be decompressed. Decompressioninvolves decoding the entropy encoded signal to reproduce the quantisedsignal. The quantisation is reversed by multiplying the quantised valuesby the corresponding quantisation parameters (applying the inverse ofthe quantisation matrix). The discrete cosine transform (or the modifiedtransform) is reversed by applying the inverse of the relevanttransform. This provides a decoded residual macroblock which can beused, along with the data required for prediction, to recover theoriginal macroblock.

According to an embodiment of the invention, the method of compressioninvolves compressing the section of the image outside of the region ofinterest but not compressing the section of the image inside the regionof interest. Accordingly, one or more of the above compression methodsmay be applied only to the section of the image outside of the region ofinterest.

In a further embodiment, a smaller degree of compression is applied tothe section of the image inside the region of interest than to thesection of the image outside the region of interest. In one embodiment,this involves applying more compression steps to the section of theimage outside the region of interest than to the section of the imageinside the region of interest.

In a further embodiment, the section of the image inside the region ofinterest does not undergo quantisation whereas the section of the imageoutside the region of interest does undergo quantisation.

In further embodiments, other compression methods, such as thosediscussed above or alternative methods known in the art, are implementedin the section of the image outside the region of interest and not inthe section of the image inside the region of interest.

In a further embodiment, the same method of compression is applied tothe region of interest as outside the region of interest; however, ahigher compression ratio is applied outside the region of interest. Inone embodiment, the transform coefficients are quantised and a finerquantisation step size is applied to the section of the image within theregion of interest than to the section of the image outside the regionof interest.

In a further embodiment, transform compression is applied to the imageand a different transform is applied to the section of the image insidethe region of interest than to the section of the image outside theregion of interest.

The above methods of compression may be implemented either in hardwareor via software executed in a controller.

FIG. 6 shows a further device 700 for compressing image and/or videodata according to an embodiment of the invention. The device 700comprises a controller 710 for compressing image and video signals andan input/output interface 720 for receiving input signals and outputtingoutput signals. The controller executes its functions based onexecutable software code stored in memory 730. The controller 710comprises the ROI computation module 120 and the compression module 110,although these may be implemented in separate controllers in analternative embodiment. In one embodiment, the device 700 isincorporated into a video encoder unit.

While certain embodiments have been described, the embodiments have beenpresented by way of example only, and are not intended to limit thescope of the inventions. For instance, whilst embodiments are describedwith reference to unmanned surface vehicles, embodiments of theinvention may equally be applied to video feeds from manned ships, andto ground vehicles, aircraft or any other application in which acamera's region of interest is likely to vary with attitude.

Furthermore, whilst specific examples of methods of compression aredescribed (for instance, applying quantisation matrices, entropy coding,etc.) embodiments of the present invention may equally be applied to anymethod of compression, provided that the position of the region ofinterest is defined based on attitude data so that camera movement maybe accounted for.

In addition, whilst embodiments of the invention relate to applying alower compression to a section of the image within the region ofinterest, this also includes applying no compression to the section ofthe image within the region of interest whilst compression the sectionof the image outside the region of interest.

Indeed, the novel methods, apparatus and systems described herein may beembodied in a variety of other forms; furthermore, various omissions,substitutions and changes in the form of the methods and systemsdescribed herein may be made without departing from the spirit of theinventions. The accompanying claims and their equivalents are intendedto cover such forms or modifications as would fall within the scope andspirit of the inventions.

1. A device for compressing image data, the device comprising acontroller configured to: receive image data comprising one or moreimages recorded by a camera; receive attitude data indicating theattitude of the camera when each of the one or more images was recorded;in each of the one or more images, define a region of interest boundedby a boundary, the boundary of the region of interest being based on theattitude data for the respective image and defining a section of theimage within the region of interest and a section of the image outsidethe region of interest; and compress each of the one or more images,wherein the compression ratio applied to the section of the imageoutside the region of interest is higher than that applied to thesection of the image within the region of interest.
 2. A deviceaccording to claim 1 wherein the controller is configured to compress,for each image, only the section of the image outside the region ofinterest.
 3. A device according to claim 1 wherein defining the regionof interest in each of the one or more images comprises transforming theboundary of the region of interest defined in a reference coordinatesystem into the boundary of the region of interest within the respectiveimage based on the attitude data for the image.
 4. A device according toclaim 3 wherein the reference coordinate system is concentric with theoptical centre of the camera and is fixed with respect to compass pointsand with respect to the local horizontal plane.
 5. A device according toclaim 3 wherein the boundary of the region of interest is defined in thereference coordinate system on a two dimensional manifold which iscarried by the reference coordinate system.
 6. A device according toclaim 5 wherein, on the manifold in the reference coordinate system, theboundary of the region of interest is static.
 7. A device according toclaim 5 wherein: the two dimensional manifold is a sphere whose centreis located at the origin of the reference coordinate system; and in thereference coordinate system, the boundary of the region of interest isdefined using a series of points located on the surface of the sphere.8. A device according to claim 3 wherein: the controller is configuredto receive a reference image, attitude data for the reference image anddata indicating the boundary of a region of interest within thereference image; and the boundary of the region of interest in thereference coordinate system is defined by transforming the boundary ofthe region of interest in the reference image into the boundary of theregion of interest in the reference coordinate system based on theattitude data for the reference image.
 9. A device according to claim 3wherein the region of interest in the reference coordinate system isdefined based on a minimum and/or maximum threshold for elevation angleand/or wherein the region of interest in the reference coordinate systemis defined based on a minimum and/or maximum threshold for azimuthangle.
 10. A device according to claim 1 wherein: the image datacomprises first and second images recorded by the camera; and theboundary of the region of interest in the second image is defined basedon a transformation applied to the boundary of the region of interest inthe first image, the transformation being based on the attitude data forthe first and second images.
 11. The device of claim 10 wherein thetransformation compensates for a change in the attitude of the camerabetween the recording of the first image and the recording of the secondimage.
 12. A method of compressing image data, the method comprising:receiving image data comprising one or more images recorded by a camera;receiving attitude data indicating the attitude of the camera when eachof the one or more images was recorded; in each of the one or moreimages, defining a region of interest bounded by a boundary, theboundary of the region of interest being based on the attitude data forthe respective image and defining a section of the image within theregion of interest and a section of the image outside the region ofinterest; and compressing each of the one or more images, wherein thecompression ratio applied to the section of the image outside the regionof interest is higher than that applied to the section of the imagewithin the region of interest.
 13. A method according to claim 12wherein compressing each of the one or more images comprises, for eachimage, compressing only the section of the image outside the region ofinterest.
 14. A method according to claim 12 wherein defining the regionof interest in each of the one or more images comprises transforming theboundary of the region of interest defined in a reference coordinatesystem into the boundary of the region of interest within the respectiveimage based on the attitude data for the image.
 15. A method accordingto claim 14 wherein the reference coordinate system is concentric withthe optical centre of the camera and is fixed with respect to compasspoints and with respect to the local horizontal plane.
 16. A methodaccording to claim 14 wherein the boundary of the region of interest isdefined in the reference coordinate system on a two dimensional manifoldwhich is carried by the reference coordinate system.
 17. A methodaccording to claim 16 wherein, on the manifold in the referencecoordinate system, the boundary of the region of interest is static. 18.A method according to claim 16 wherein: the two dimensional manifold isa sphere whose centre is located at the origin of the referencecoordinate system; and in the reference coordinate system, the boundaryof the region of interest is defined using a series of points located onthe surface of the sphere.
 19. A method according to claim 14 wherein:the method further comprises receiving a reference image, attitude datafor the reference image and data indicating the boundary of a region ofinterest within the reference image; and the boundary of the region ofinterest in the reference coordinate system is defined by transformingthe boundary of the region of interest in the reference image into theboundary of the region of interest in the reference coordinate systembased on the attitude data for the reference image.
 20. A methodaccording to claim 14 wherein the region of interest in the referencecoordinate system is defined based on a minimum and/or maximum thresholdfor elevation angle and/or wherein the region of interest in thereference coordinate system is defined based on a minimum and/or maximumthreshold for azimuth angle.